<?php
$config=[
    'development'=>[
        "apiHost"=>'http://www.b.com/',
        "webSocketPort"=>8088,
        "httpPort"=>8089,
        "pwd"=>'socket',//管理员密码
        "db"=>[
            "host"=>'127.0.0.1',
            "port"=>3306,
            "database"=>'data',
            "prefix"=>'t_',
            "user"=>'root',
            "password"=>'root',
        ]
    ],
    'production'=>[
        "apiHost"=>'http://veishou.com/',
        "webSocketPort"=>00,
        "httpPort"=>01,
        "pwd"=>'',//管理员密码
        "db"=>[
            "host"=>'127.0.0.1',
            "port"=>3306,
            "database"=>'',
            "prefix"=>'',
            "user"=>'',
            "password"=>'',
        ]
    ]
];
$env='development'; //production
if(isset($argv)){
    $envIndex=array_search('--env', $argv);
    if(is_integer($envIndex)){
        $i=$envIndex+1;
        $env=isset($argv[$i])?$argv[$i]:$env;

    }
}

return $config[$env];